from typing import Optional, List

__all__ = ['Workspace', 'TypeDef', 'StructureNode']

class Workspace:

    def __init__(self, ws_path: str) -> None: ...
    def query_function(self, path: str, fn_signature: str) -> Optional[List[int]]: ...
    def query_typedef(self, path: str, ty_name: str) -> Optional[List[int]]: ...
    def get_typedefs(self, path: str, offset: int) -> List[TypeDef]: ...
    def get_impl_file_structures(self, path: str, offset: int) -> List[List[StructureNode]]: ...


class TypeDef:
    path: str
    name: str
    description: str
    offset: int # offset in file, not considered in __eq__ and __hash__

    def __repr__(self) -> str: ...
    def __hash__(self) -> int: ...
    def __eq__(self, other: 'TypeDef') -> bool: ...


class StructureNode:
    ppid: Optional[int]
    label: str
    kind: str
    detail: str

    def __repr__(self) -> str: ...
    def __hash__(self) -> int: ...
